package com.mg.smarttask.client;

import com.google.gwt.event.dom.client.ClickEvent;
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.user.client.ui.Button;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.RootPanel;
import com.google.gwt.user.client.ui.VerticalPanel;
import com.google.gwt.user.client.ui.HTML;

public class InfoST extends Composite {

	public InfoST() {
		VerticalPanel verticalPanel = new VerticalPanel();
		verticalPanel.setStyleName("loginPanel");
		initWidget(verticalPanel);
		verticalPanel.setSize("450px", "250px");
		
		Label titleLabel = new Label("What is SmartTask ?");
		titleLabel.setStyleName("h2");
		verticalPanel.add(titleLabel);
		titleLabel.setHeight("30");
		
		HTML htmlJo = new HTML("<p> Lorem ipsum dolor sit amet, consectetur adipiscing elit. " +
				"Nunc dignissim eros nec justo venenatis et convallis diam lacinia. Curabitur" +
				" tempus bibendum nunc nec pellentesque. Nunc viverra venenatis auctor. Cras " +
				"quis orci eget purus bibendum tristique. Phasellus vitae nunc felis. Sed " +
				"gravida ligula a ipsum sodales vel egestas odio faucibus. Aliquam fringilla " +
				"tempus nibh, nec molestie magna tempor eget. Vestibulum ante ipsum primis in " +
				"faucibus orci luctus et ultrices posuere cubilia Curae; Donec scelerisque " +
				"hendrerit purus, eu sagittis justo euismod at. </p>", true);
		htmlJo.setStyleName("p");
		verticalPanel.add(htmlJo);
		
		Button btnSeConnecter = new Button("Se connecter");
		btnSeConnecter.addClickHandler(new ClickHandler() {
			public void onClick(ClickEvent event) {
				RootPanel rootPanel = RootPanel.get();
				rootPanel.add(new HTML("yo"));
			}
		});

		verticalPanel.add(btnSeConnecter);
		btnSeConnecter.setStyleName("connectButton");
	
		btnSeConnecter.setSize("100px", "25px");
		
		Button button = new Button("Se connecter");
		button.setText("S'enregistrer");
		button.setStyleName("connectButton");
		verticalPanel.add(button);
		button.setSize("100px", "25px");
	}

	
}
